package com.locus.tools.xmpp;


/**
 * Implements functionality to recieve messages from the XMPPAgent class, parse them, and return them to the original
 * XMPP-requesting class.
 * @author jfredett
 *
 */
public interface IRecievable {
	
	/**
	 * Returns the sender of the message
	 * @return the senders name.
	 */
	public String getSender();
	/**
	 * Gets the message contained
	 * @return the Message text
	 */
	public String getMessage();
	/**
	 * Gets the intended Recipient of the message
	 * @return the Recipient's name.
	 */
	public String getRecipient();
	
	/**
	 * Fills in the {@link IRecievable} instance with given data, @see com.locus.tools.xmpp.GTalkAgent,
	 * allows for some parsing on the way in.
	 * @param from
	 * @param msg
	 * @param to
	 * @return <br>
	 * the same {@link IRecievable} instance, but with new data.
	 * 
	 */
	public IRecievable createRecievable(String from, String msg, String to);
	
}
